package com.cainiao.stock.response;

import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@JsonInclude(JsonInclude.Include.NON_NULL)
public class PageResult<T> {

    /**
     * 总行数
     */
    private long totalRows;

    /**
     * 总页数
     */
    private int totalPages;

    /**
     * 当前页
     */
    private int pageNum;

    /**
     * 每页大小
     */
    private int pageSize;

    /**
     * 当前页大小
     */
    private int size;

    /**
     * 数据
     */
    private List<T> rows;

}
